package com.xingda.packing.dmss.plc.service;

import com.alibaba.fastjson.JSONObject;
import com.xingda.packing.dmss.plc.entity.PlcItem;
import com.xingda.packing.dmss.plc.entity.PlcItemVal;

import java.util.List;

public interface PlcHandleService {

    /**
     * 读取PLC项数据
     *
     * @param plcItems PlcItem数组
     */
    JSONObject readItem(PlcItem... plcItems);

    /**
     * 写入PLC项数据
     *
     * @param plcItemVals PlcItemVal数组
     */
    boolean writeItem(PlcItemVal... plcItemVals);

    /**
     * 写入PLC项数据
     *
     * @param plcItemVals PlcItemVal集合
     */
    boolean writeItem(List<PlcItemVal> plcItemVals);

}
